3.2.50 \(\int \csc ^3(c+d x) (a+a \sec (c+d x))^n \, dx\) [150]

3.2.50.1 Optimal result
3.2.50.2 Mathematica [A] (verified)
3.2.50.3 Rubi [A] (verified)
3.2.50.4 Maple [F]
3.2.50.5 Fricas [F]
3.2.50.6 Sympy [F]
3.2.50.7 Maxima [F]
3.2.50.8 Giac [F]
3.2.50.9 Mupad [F(-1)]

3.2.50.1 Optimal result

Integrand size = 21, antiderivative size = 112 \[ \int \csc ^3(c+d x) (a+a \sec (c+d x))^n \, dx=-\frac {a (2-n) (a+a \sec (c+d x))^{-1+n}}{4 d (1-n)}+\frac {a (a+a \sec (c+d x))^{-1+n}}{2 d (1-\sec (c+d x))}-\frac {(2+n) \operatorname {Hypergeometric2F1}\left (1,n,1+n,\frac {1}{2} (1+\sec (c+d x))\right ) (a+a \sec (c+d x))^n}{8 d n} \]

output
-1/4*a*(2-n)*(a+a*sec(d*x+c))^(-1+n)/d/(1-n)+1/2*a*(a+a*sec(d*x+c))^(-1+n) 
/d/(1-sec(d*x+c))-1/8*(2+n)*hypergeom([1, n],[1+n],1/2+1/2*sec(d*x+c))*(a+ 
a*sec(d*x+c))^n/d/n
 
3.2.50.2 Mathematica [A] (verified)

Time = 1.07 (sec) , antiderivative size = 179, normalized size of antiderivative = 1.60 \[ \int \csc ^3(c+d x) (a+a \sec (c+d x))^n \, dx=\frac {\cos (c+d x) \sec ^2\left (\frac {1}{2} (c+d x)\right ) (1+\sec (c+d x))^{-n} (a (1+\sec (c+d x)))^n \left (2^{1+n} \operatorname {Hypergeometric2F1}\left (1,1-n,2-n,\cos (c+d x) \sec ^2\left (\frac {1}{2} (c+d x)\right )\right ) \left (\cos ^2\left (\frac {1}{2} (c+d x)\right ) \sec (c+d x)\right )^n+2^n \operatorname {Hypergeometric2F1}\left (2,1-n,2-n,\cos (c+d x) \sec ^2\left (\frac {1}{2} (c+d x)\right )\right ) \left (\cos ^2\left (\frac {1}{2} (c+d x)\right ) \sec (c+d x)\right )^n+(1+\sec (c+d x))^n\right )}{8 d (-1+n)} \]

input
Integrate[Csc[c + d*x]^3*(a + a*Sec[c + d*x])^n,x]
 
output
(Cos[c + d*x]*Sec[(c + d*x)/2]^2*(a*(1 + Sec[c + d*x]))^n*(2^(1 + n)*Hyper 
geometric2F1[1, 1 - n, 2 - n, Cos[c + d*x]*Sec[(c + d*x)/2]^2]*(Cos[(c + d 
*x)/2]^2*Sec[c + d*x])^n + 2^n*Hypergeometric2F1[2, 1 - n, 2 - n, Cos[c + 
d*x]*Sec[(c + d*x)/2]^2]*(Cos[(c + d*x)/2]^2*Sec[c + d*x])^n + (1 + Sec[c 
+ d*x])^n))/(8*d*(-1 + n)*(1 + Sec[c + d*x])^n)
 
3.2.50.3 Rubi [A] (verified)

Time = 0.30 (sec) , antiderivative size = 123, normalized size of antiderivative = 1.10, number of steps used = 9, number of rules used = 8, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.381, Rules used = {3042, 4361, 27, 100, 25, 27, 88, 78}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int \csc ^3(c+d x) (a \sec (c+d x)+a)^n \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {\left (a-a \csc \left (c+d x-\frac {\pi }{2}\right )\right )^n}{\cos \left (c+d x-\frac {\pi }{2}\right )^3}dx\)

\(\Big \downarrow \) 4361

\(\displaystyle -\frac {a^4 \int \frac {\sec ^2(c+d x) (\sec (c+d x) a+a)^{n-2}}{a^2 (1-\sec (c+d x))^2}d(-\sec (c+d x))}{d}\)

\(\Big \downarrow \) 27

\(\displaystyle -\frac {a^2 \int \frac {\sec ^2(c+d x) (\sec (c+d x) a+a)^{n-2}}{(1-\sec (c+d x))^2}d(-\sec (c+d x))}{d}\)

\(\Big \downarrow \) 100

\(\displaystyle -\frac {a^2 \left (\frac {\int -\frac {a (n+2 \sec (c+d x)) (\sec (c+d x) a+a)^{n-2}}{1-\sec (c+d x)}d(-\sec (c+d x))}{2 a}-\frac {(a \sec (c+d x)+a)^{n-1}}{2 a (1-\sec (c+d x))}\right )}{d}\)

\(\Big \downarrow \) 25

\(\displaystyle -\frac {a^2 \left (-\frac {\int \frac {a (n+2 \sec (c+d x)) (\sec (c+d x) a+a)^{n-2}}{1-\sec (c+d x)}d(-\sec (c+d x))}{2 a}-\frac {(a \sec (c+d x)+a)^{n-1}}{2 a (1-\sec (c+d x))}\right )}{d}\)

\(\Big \downarrow \) 27

\(\displaystyle -\frac {a^2 \left (-\frac {1}{2} \int \frac {(n+2 \sec (c+d x)) (\sec (c+d x) a+a)^{n-2}}{1-\sec (c+d x)}d(-\sec (c+d x))-\frac {(a \sec (c+d x)+a)^{n-1}}{2 a (1-\sec (c+d x))}\right )}{d}\)

\(\Big \downarrow \) 88

\(\displaystyle -\frac {a^2 \left (\frac {1}{2} \left (\frac {(2-n) (a \sec (c+d x)+a)^{n-1}}{2 a (1-n)}-\frac {(n+2) \int \frac {(\sec (c+d x) a+a)^{n-1}}{1-\sec (c+d x)}d(-\sec (c+d x))}{2 a}\right )-\frac {(a \sec (c+d x)+a)^{n-1}}{2 a (1-\sec (c+d x))}\right )}{d}\)

\(\Big \downarrow \) 78

\(\displaystyle -\frac {a^2 \left (\frac {1}{2} \left (\frac {(n+2) (a \sec (c+d x)+a)^n \operatorname {Hypergeometric2F1}\left (1,n,n+1,\frac {1}{2} (\sec (c+d x)+1)\right )}{4 a^2 n}+\frac {(2-n) (a \sec (c+d x)+a)^{n-1}}{2 a (1-n)}\right )-\frac {(a \sec (c+d x)+a)^{n-1}}{2 a (1-\sec (c+d x))}\right )}{d}\)

input
Int[Csc[c + d*x]^3*(a + a*Sec[c + d*x])^n,x]
 
output
-((a^2*(-1/2*(a + a*Sec[c + d*x])^(-1 + n)/(a*(1 - Sec[c + d*x])) + (((2 - 
 n)*(a + a*Sec[c + d*x])^(-1 + n))/(2*a*(1 - n)) + ((2 + n)*Hypergeometric 
2F1[1, n, 1 + n, (1 + Sec[c + d*x])/2]*(a + a*Sec[c + d*x])^n)/(4*a^2*n))/ 
2))/d)
 

3.2.50.3.1 Defintions of rubi rules used

rule 25
Int[-(Fx_), x_Symbol] :> Simp[Identity[-1]   Int[Fx, x], x]
 

rule 27
Int[(a_)*(Fx_), x_Symbol] :> Simp[a   Int[Fx, x], x] /; FreeQ[a, x] &&  !Ma 
tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
 

rule 78
Int[((a_) + (b_.)*(x_))^(m_)*((c_) + (d_.)*(x_))^(n_), x_Symbol] :> Simp[(b 
*c - a*d)^n*((a + b*x)^(m + 1)/(b^(n + 1)*(m + 1)))*Hypergeometric2F1[-n, m 
 + 1, m + 2, (-d)*((a + b*x)/(b*c - a*d))], x] /; FreeQ[{a, b, c, d, m}, x] 
 &&  !IntegerQ[m] && IntegerQ[n]
 

rule 88
Int[((a_.) + (b_.)*(x_))*((c_.) + (d_.)*(x_))^(n_.)*((e_.) + (f_.)*(x_))^(p 
_.), x_] :> Simp[(-(b*e - a*f))*(c + d*x)^(n + 1)*((e + f*x)^(p + 1)/(f*(p 
+ 1)*(c*f - d*e))), x] - Simp[(a*d*f*(n + p + 2) - b*(d*e*(n + 1) + c*f*(p 
+ 1)))/(f*(p + 1)*(c*f - d*e))   Int[(c + d*x)^n*(e + f*x)^Simplify[p + 1], 
 x], x] /; FreeQ[{a, b, c, d, e, f, n, p}, x] &&  !RationalQ[p] && SumSimpl 
erQ[p, 1]
 

rule 100
Int[((a_.) + (b_.)*(x_))^2*((c_.) + (d_.)*(x_))^(n_)*((e_.) + (f_.)*(x_))^( 
p_), x_] :> Simp[(b*c - a*d)^2*(c + d*x)^(n + 1)*((e + f*x)^(p + 1)/(d^2*(d 
*e - c*f)*(n + 1))), x] - Simp[1/(d^2*(d*e - c*f)*(n + 1))   Int[(c + d*x)^ 
(n + 1)*(e + f*x)^p*Simp[a^2*d^2*f*(n + p + 2) + b^2*c*(d*e*(n + 1) + c*f*( 
p + 1)) - 2*a*b*d*(d*e*(n + 1) + c*f*(p + 1)) - b^2*d*(d*e - c*f)*(n + 1)*x 
, x], x], x] /; FreeQ[{a, b, c, d, e, f, n, p}, x] && (LtQ[n, -1] || (EqQ[n 
 + p + 3, 0] && NeQ[n, -1] && (SumSimplerQ[n, 1] ||  !SumSimplerQ[p, 1])))
 

rule 3042
Int[u_, x_Symbol] :> Int[DeactivateTrig[u, x], x] /; FunctionOfTrigOfLinear 
Q[u, x]
 

rule 4361
Int[cos[(e_.) + (f_.)*(x_)]^(p_.)*(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m 
_), x_Symbol] :> Simp[-(f*b^(p - 1))^(-1)   Subst[Int[(-a + b*x)^((p - 1)/2 
)*((a + b*x)^(m + (p - 1)/2)/x^(p + 1)), x], x, Csc[e + f*x]], x] /; FreeQ[ 
{a, b, e, f, m}, x] && IntegerQ[(p - 1)/2] && EqQ[a^2 - b^2, 0]
 
3.2.50.4 Maple [F]

\[\int \csc \left (d x +c \right )^{3} \left (a +a \sec \left (d x +c \right )\right )^{n}d x\]

input
int(csc(d*x+c)^3*(a+a*sec(d*x+c))^n,x)
 
output
int(csc(d*x+c)^3*(a+a*sec(d*x+c))^n,x)
 
3.2.50.5 Fricas [F]

\[ \int \csc ^3(c+d x) (a+a \sec (c+d x))^n \, dx=\int { {\left (a \sec \left (d x + c\right ) + a\right )}^{n} \csc \left (d x + c\right )^{3} \,d x } \]

input
integrate(csc(d*x+c)^3*(a+a*sec(d*x+c))^n,x, algorithm="fricas")
 
output
integral((a*sec(d*x + c) + a)^n*csc(d*x + c)^3, x)
 
3.2.50.6 Sympy [F]

\[ \int \csc ^3(c+d x) (a+a \sec (c+d x))^n \, dx=\int \left (a \left (\sec {\left (c + d x \right )} + 1\right )\right )^{n} \csc ^{3}{\left (c + d x \right )}\, dx \]

input
integrate(csc(d*x+c)**3*(a+a*sec(d*x+c))**n,x)
 
output
Integral((a*(sec(c + d*x) + 1))**n*csc(c + d*x)**3, x)
 
3.2.50.7 Maxima [F]

\[ \int \csc ^3(c+d x) (a+a \sec (c+d x))^n \, dx=\int { {\left (a \sec \left (d x + c\right ) + a\right )}^{n} \csc \left (d x + c\right )^{3} \,d x } \]

input
integrate(csc(d*x+c)^3*(a+a*sec(d*x+c))^n,x, algorithm="maxima")
 
output
integrate((a*sec(d*x + c) + a)^n*csc(d*x + c)^3, x)
 
3.2.50.8 Giac [F]

\[ \int \csc ^3(c+d x) (a+a \sec (c+d x))^n \, dx=\int { {\left (a \sec \left (d x + c\right ) + a\right )}^{n} \csc \left (d x + c\right )^{3} \,d x } \]

input
integrate(csc(d*x+c)^3*(a+a*sec(d*x+c))^n,x, algorithm="giac")
 
output
integrate((a*sec(d*x + c) + a)^n*csc(d*x + c)^3, x)
 
3.2.50.9 Mupad [F(-1)]

Timed out. \[ \int \csc ^3(c+d x) (a+a \sec (c+d x))^n \, dx=\int \frac {{\left (a+\frac {a}{\cos \left (c+d\,x\right )}\right )}^n}{{\sin \left (c+d\,x\right )}^3} \,d x \]

input
int((a + a/cos(c + d*x))^n/sin(c + d*x)^3,x)
 
output
int((a + a/cos(c + d*x))^n/sin(c + d*x)^3, x)